package com.decapre.zufangwang.service;

import com.decapre.zufangwang.entity.District;
import com.decapre.zufangwang.repository.DistrictRepository;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.HashMap;
import java.util.List;
import java.util.Map;

@Service
public class DistrictServiceImpl implements DistrictService {
    private DistrictRepository districtRepository;

    @Autowired
    public DistrictServiceImpl(DistrictRepository districtRepository){
        this.districtRepository = districtRepository;
    }

    @Override
    public List<District> getAllDistrict() {
        return districtRepository.getAllDistricts();
    }
}
